package net.oschina.app.pages;

import android.widget.TextView;

import com.robotium.solo.Solo;

import net.oschina.app.SoloWrap;

/**
 * Created by Aaron on 2017/10/29.
 */

public class PageHome  {
    private SoloWrap soloWrap;

    public PageHome(SoloWrap soloWrap){
        this.soloWrap = soloWrap;
    }

    public void clickListItem(int index){
        soloWrap.clickOnListItem(index);
    }

    public String getNewsTitle(int index){
        return  soloWrap.getText((TextView) soloWrap.findById("net.oschina.app:id/tv_title",index - 1));
    }

}
